<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <style>
        body {
            width: 300px;
            height: 360px;
            font-family: Arial, sans-serif;
        }
        .container {
            display: flex;
            flex-direction: column;
            gap: 15px;
            overflow: hidden;
        }
        .logo {
            width: 70px;
            height: 70px;
            display: block;
            margin: 27px auto 7px;
        }
        .title {
            width: 100%;
            text-align: center;
            color: #010101;
            font-size: 20px;
        }
        .input-group {
            display: flex;
            flex-direction: row;
            gap: 5px;
            margin-bottom: 10px;
        }
        .txt {
            width: 50px;
            text-align: right;
            height: 30px;
            line-height: 34px;
            margin-right: 10px;
            font-size: 12px;
        }
        input {
            padding: 8px;
            border: 1px solid #ddd;
            border-radius: 4px;
        }
        button {
            background-color: #010101;
            color: white;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 14px;
            width: 100px;
            height: 30px;
            margin: 20px auto 0;
            display: block;
        }
        button:hover {
            background-color: #f01844;
        }
        .status {
            text-align: center;
            margin-top: 10px;
            color: #666;
        }
        .error {
            color: #ff4444;
            font-size: 12px;
            display: none;
        }
    </style>
</head>
<body>
    <div class="container">
        <img class="logo" src="./images/icon128.png" alt="">
        <div class="title">美刻-创意魔方</div>
        <div id="loginForm">
            <div class="input-group">
                <div class="txt" for="phone">账号</div>
                <input type="tel" id="phone" placeholder="请输入手机号码" pattern="[0-9]{11}">
            </div>
            <div class="error" id="phoneError">请输入有效的手机号码</div>
            <div class="input-group">
                <div class="txt" for="password">密码</div>
                <input type="password" id="password" placeholder="请输入密码">
            </div>
            <div class="error" id="passwordError">密码不能为空</div>
            <button id="loginBtn">登录</button>
        </div>
        <div id="userInfo" style="display: none;">
            <p style="text-align: center;">已登录</p>
            <button id="logoutBtn">退出登录</button>
        </div>
        <div class="status" id="status"></div>
    </div>
    <script src="popup.js"></script>
</body>
</html> 